package active.iterators;

import constructor.composite.Deparment;

import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;

public class InfoCollege implements College {

    List<Deparment> deparmentList;

    public InfoCollege() {
        deparmentList = new ArrayList<>();
        deparmentList.add(new Deparment("信息工程系1", "abc"));
        deparmentList.add(new Deparment("信息工程系2", "abc"));
    }

    @Override
    public String getName() {
        return "通信学院";
    }

    @Override
    public Iterator createIterator() {
        return new InfoCollegeIterator(deparmentList);
    }
}
